/**
 * Created by zhang.xu on 2016/4/26.
 */

var mongoose = require('mongoose');
var Schema = mongoose.Schema;

//骨架模板
var productSchema = new Schema({
    //产品名称
    productName: String,
    //产品价格
    productPrice: Number,
    //标题
    title: String,
    //供需类型
    saleDemand: String,
    //新旧程度
    newOrOldDegree: String,
    //交易类型
    purchaseType: String,
    //联系人
    contactPerson: String,
    //联系电话
    phoneNumber: String,
    //产品描述
    description: String,
    //产品类型
    productType: String,
    //关联用户
    userId: String
});

exports.product = mongoose.model('Product', productSchema);